/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ServiceBasedSystem;

import DatabaseConnectivity.MySQLConnectivity;
import RatingMatrix.ArrayRateMatrix;
import java.sql.SQLException;

/**
 *
 * @author Ekantik
 */
public class ServiceBasedRatingsDB {

    private String query;

    public ArrayRateMatrix getAlrm() {
        return alrm;
    }

    public void setAlrm(ArrayRateMatrix alrm) {
        this.alrm = alrm;
    }

    public String getQuery() {
        return query;
    }

    public void setQuery(String query) {
        this.query = query;
    }
    
    public ServiceBasedRatingsDB() {

    }
    public static void main(String args[]){
        MySQLConnectivity msc = new MySQLConnectivity();
        String query = "Select * from ratings;";
        msc.getSelectTable(query);
        try{
            while(msc.getResultSet().next()){
                System.out.print(msc.getResultSet().getInt(1));
                System.out.print("\t|" + msc.getResultSet().getString(2));
                System.out.print("\t|" +msc.getResultSet().getInt(3));
                System.out.print("\t|" +msc.getResultSet().getInt(4));
                System.out.println();
            }
        }
        catch(SQLException ex){
            msc.log(ex);
        }
        }
    public void closeDB(){
        

    }
    
}
